package com.hq.myapplicationdemo.model;

import com.chad.library.adapter.base.entity.MultiItemEntity;
import com.hq.myapplicationdemo.model.enums.AdapterModel;

import java.io.Serializable;
import java.util.List;
import java.util.Objects;

public class HousingInfoBean implements Serializable, MultiItemEntity {
    public static final int TYPE_COMMON = 1;//正常
    public static final int TYPE_Line = 2;//分隔
    public static final int TYPE_NEAR = 3;//附近
    public static final int TYPE_NOMORE= 4;//附近

    private int  item= AdapterModel.List.getIndex();//默认是列表
    public void setItem(int item) {
        this.item = item;
    }


    /**
     * 小区信息
     */
    private CommunityInformation communityInformation;

    /**
     * 小区ID
     */
    private Integer communityInformationId;

    /**
     * 是否已点亮
     */
    private boolean isLight;

    /**
     * 浏览量
     */
    private int pageviews;
    /**
     *主动咨询次数
     */
    private int advisoryNumber;
    /**
     *被推荐次数
     */
    private int recommendedNumber;
    /**
     *收藏数量
     */
    private int collectNumber;
    /**
     *点亮时间
     */
    private String lightUpTime;
    //视频封面
    private String videoCover;
    /**
     * 区分我的收藏、我的发布
     */
    private String remark;

    private int collectId;
    /**
     * 房源ID
     */
    private String housingId;

    /**
     * 视频
     */
    private String video;

    /**
     * 交铺时间
     */
    private String handoverTime;

    /**
     * 联系人
     */
    private String contactPerson;

    /**
     * 联系电话
     */
    private String contactNumber;

    /**
     * 发布者id
     */
    private Integer userId;

    /**
     * 编号（自动生成）13+5位随机数字
     */
    private String houseNo;

    /**
     * 店铺名
     */
    private String storeName;

    /**
     * 正面照
     */
    private String frontPicture;

    /**
     * 左侧照
     */
    private String leftPicture;

    /**
     * 右侧照
     */
    private String rightPicture;

    /**
     * 经营状态：空铺，经营中
     */
    private Integer businessStatus;

    /**
     * 当前经营业态,经营业态表ID
     */
    private Integer currentBusinessConditionsId;

    /**
     * 月租金(元/月)
     */
    private double monthlyRent;

    /**
     * 支付方式:月付，季付，半年付，年付(字典表)
     */
    private Integer paymentMethod;

    /**
     * 最短租约(多少个月)
     */
    private Integer shortestLease;

    /**
     * 最长租约(多少个月)
     */
    private Integer longestLease;

    /**
     * 剩余租期(多少个月)
     */
    private Integer remainingLease;

    /**
     * 押金（X月房租） -1为面议
     */
    private Integer cashPledge;

    /**
     * 房东直租,是，否
     */

    private Boolean straightLandlordRent;

    /**
     * 转让状态，有，无，面议(字典表)
     */
    private Integer transfer;

    /**
     * 转让费用(万元)  当转让状态为3（面议）时，此值为-1
     */
    private double transferFee;

    /**
     * 免租期，0代表无(无或具体天数)
     */
    private Integer rentFreePeriod;

    /**
     * 是否空转
     */

    private Boolean whetherIdling;

    /**
     * 建筑面积(平米)
     */
    private Float constructionArea;

    /**
     * 面宽(米)
     */
    private Float width;

    /**
     * 层高(米)
     */
    private Float high;

    /**
     * 所在楼层
     */
    private String floor;

    /**
     * 所在楼层数字
     */
    private String floors;

    /**
     * 物业费(XX元/月/㎡)
     */
    private Float propertyCosts;

    /**
     * 物业类型(字典表)
     */
    private Integer propertyType;

    /**
     * 是否临街
     */

    private Boolean whetherStreet;

    /**
     * 同意租客电话直接联系
     */

    private Boolean contactDirectly;

    /**
     * 同意中介帮转
     */

    private Boolean agreeToHelp;

    /**
     * 成交状态
     */

    private Boolean transactionStatus;

    /**
     * 认证状态
     */

    private Boolean certificationStatus;

    /**
     * 置顶状态
     */

    private Boolean pinned;

    /**
     * 地址id
     */
    private Integer addressId;

    /**
     * 店铺评估合格证图片
     */
    private String certificatePicture;

    /**
     * 发布时间
     */
    private String releaseDate;

    /**
     * 审核状态
     */
    private Integer approvalStatus;

    /**
     * 标题（自动生成，根据规则）
     */
    private String title;

    /**
     * 图片
     */
    private String pictures;

    /**
     * 周边热铺
     */
    private String peripheralHotShop;

    /**
     * 店主自述
     */
    private String ownerReadme;

    /**
     * 房源标签
     */
    private List<HousingLabelBean> housingLabelList;

    /**
     * 图片数组
     */
    private List<String> picturesList;

    /**
     * 房源配套设施
     */
    private List<HousingSupportingFacilitiesBean> housingSupportingFacilitiesList;

    /**
     * 地址对象
     */
    private AddressBean address;



    /**
     * 经营状态字典
     */
    private DictBean businessStatusDict;

    /**
     * 支付方式字典
     */
    private DictBean paymentMethodDict;

    /**
     * 转让状态字典
     */
    private DictBean transferDict;

    /**
     * 物业类型字典
     */
    private DictBean propertyTypeDict;

    /**
     * 层高字典
     */
    private DictBean floorDict;

    /**
     * 经营业态list
     */
    private List<HousingOperatingIndustryBean> industryList;

    /**
     * 当前经营业态
     */
    private IndustryBean businessIndustry;

    public String getFloors() {
        return floors;
    }

    public void setFloors(String floors) {
        this.floors = floors;
    }

    public boolean isLight() {
        return isLight;
    }

    public void setLight(boolean light) {
        isLight = light;
    }

    public int getAdvisoryNumber() {
        return advisoryNumber;
    }

    public void setAdvisoryNumber(int advisoryNumber) {
        this.advisoryNumber = advisoryNumber;
    }

    public int getRecommendedNumber() {
        return recommendedNumber;
    }

    public void setRecommendedNumber(int recommendedNumber) {
        this.recommendedNumber = recommendedNumber;
    }

    public int getCollectNumber() {
        return collectNumber;
    }

    public void setCollectNumber(int collectNumber) {
        this.collectNumber = collectNumber;
    }

    public String getLightUpTime() {
        return lightUpTime;
    }

    public void setLightUpTime(String lightUpTime) {
        this.lightUpTime = lightUpTime;
    }

    public int getPageviews() {
        return pageviews;
    }

    public void setPageviews(int pageviews) {
        this.pageviews = pageviews;
    }

    public String getVideoCover() {
        return videoCover;
    }

    public void setVideoCover(String videoCover) {
        this.videoCover = videoCover;
    }

    public String getVideo() {
        return video;
    }

    public void setVideo(String video) {
        this.video = video;
    }

    public String getHandoverTime() {
        return handoverTime;
    }

    public void setHandoverTime(String handoverTime) {
        this.handoverTime = handoverTime;
    }

    public String getContactPerson() {
        return contactPerson;
    }

    public void setContactPerson(String contactPerson) {
        this.contactPerson = contactPerson;
    }

    public String getContactNumber() {
        return contactNumber;
    }

    public void setContactNumber(String contactNumber) {
        this.contactNumber = contactNumber;
    }

    public int getCollectId() {
        return collectId;
    }

    public void setCollectId(int collectId) {
        this.collectId = collectId;
    }

    public IndustryBean getBusinessIndustry() {
        return businessIndustry == null ? new IndustryBean() : businessIndustry;
    }

    public void setBusinessIndustry(IndustryBean businessIndustry) {
        this.businessIndustry = businessIndustry;
    }

    public String getHousingId() {
        return housingId;
    }

    public void setHousingId(String housingId) {
        this.housingId = housingId;
    }

    public Integer getUserId() {
        return userId;
    }

    public void setUserId(Integer userId) {
        this.userId = userId;
    }

    public String getHouseNo() {
        return houseNo;
    }

    public void setHouseNo(String houseNo) {
        this.houseNo = houseNo;
    }

    public String getStoreName() {
        return storeName;
    }

    public void setStoreName(String storeName) {
        this.storeName = storeName;
    }

    public String getFrontPicture() {
        return frontPicture;
    }

    public void setFrontPicture(String frontPicture) {
        this.frontPicture = frontPicture;
    }

    public String getLeftPicture() {
        return leftPicture;
    }

    public void setLeftPicture(String leftPicture) {
        this.leftPicture = leftPicture;
    }

    public String getRightPicture() {
        return rightPicture;
    }

    public void setRightPicture(String rightPicture) {
        this.rightPicture = rightPicture;
    }

    public Integer getBusinessStatus() {
        return businessStatus;
    }

    public void setBusinessStatus(Integer businessStatus) {
        this.businessStatus = businessStatus;
    }

    public Integer getCurrentBusinessConditionsId() {
        return currentBusinessConditionsId;
    }

    public void setCurrentBusinessConditionsId(Integer currentBusinessConditionsId) {
        this.currentBusinessConditionsId = currentBusinessConditionsId;
    }


    public double getMonthlyRent() {
        return monthlyRent;
    }

    public void setMonthlyRent(double monthlyRent) {
        this.monthlyRent = monthlyRent;
    }

    public Integer getPaymentMethod() {
        return paymentMethod;
    }

    public void setPaymentMethod(Integer paymentMethod) {
        this.paymentMethod = paymentMethod;
    }

    public Integer getShortestLease() {
        return shortestLease;
    }

    public void setShortestLease(Integer shortestLease) {
        this.shortestLease = shortestLease;
    }

    public Integer getLongestLease() {
        return longestLease;
    }

    public void setLongestLease(Integer longestLease) {
        this.longestLease = longestLease;
    }

    public Integer getRemainingLease() {
        return remainingLease;
    }

    public void setRemainingLease(Integer remainingLease) {
        this.remainingLease = remainingLease;
    }

    public Integer getCashPledge() {
        return cashPledge;
    }

    public void setCashPledge(Integer cashPledge) {
        this.cashPledge = cashPledge;
    }

    public Boolean getStraightLandlordRent() {
        return straightLandlordRent;
    }

    public void setStraightLandlordRent(Boolean straightLandlordRent) {
        this.straightLandlordRent = straightLandlordRent;
    }

    public Integer getTransfer() {
        return transfer;
    }

    public void setTransfer(Integer transfer) {
        this.transfer = transfer;
    }

    public double getTransferFee() {
        return transferFee;
    }

    public void setTransferFee(double transferFee) {
        this.transferFee = transferFee;
    }

    public Integer getRentFreePeriod() {
        return rentFreePeriod;
    }

    public void setRentFreePeriod(Integer rentFreePeriod) {
        this.rentFreePeriod = rentFreePeriod;
    }

    public Boolean getWhetherIdling() {
        return whetherIdling;
    }

    public void setWhetherIdling(Boolean whetherIdling) {
        this.whetherIdling = whetherIdling;
    }

    public Float getConstructionArea() {
        return constructionArea;
    }



    public String getFloor() {
        return floor;
    }

    public void setFloor(String floor) {
        this.floor = floor;
    }

    public void setConstructionArea(Float constructionArea) {
        this.constructionArea = constructionArea;
    }

    public Float getWidth() {
        return width;
    }

    public void setWidth(Float width) {
        this.width = width;
    }

    public Float getHigh() {
        return high;
    }

    public void setHigh(Float high) {
        this.high = high;
    }

    public Float getPropertyCosts() {
        return propertyCosts;
    }

    public void setPropertyCosts(Float propertyCosts) {
        this.propertyCosts = propertyCosts;
    }

    public Integer getPropertyType() {
        return propertyType;
    }

    public void setPropertyType(Integer propertyType) {
        this.propertyType = propertyType;
    }

    public Boolean getWhetherStreet() {
        return whetherStreet;
    }

    public void setWhetherStreet(Boolean whetherStreet) {
        this.whetherStreet = whetherStreet;
    }

    public Boolean getContactDirectly() {
        return contactDirectly != null;
    }

    public void setContactDirectly(Boolean contactDirectly) {
        this.contactDirectly = contactDirectly;
    }

    public Boolean getAgreeToHelp() {
        return agreeToHelp;
    }

    public void setAgreeToHelp(Boolean agreeToHelp) {
        this.agreeToHelp = agreeToHelp;
    }

    public Boolean getTransactionStatus() {
        return transactionStatus;
    }

    public void setTransactionStatus(Boolean transactionStatus) {
        this.transactionStatus = transactionStatus;
    }

    public Boolean getCertificationStatus() {
        return certificationStatus;
    }

    public void setCertificationStatus(Boolean certificationStatus) {
        this.certificationStatus = certificationStatus;
    }

    public Boolean getPinned() {
        return pinned;
    }

    public void setPinned(Boolean pinned) {
        this.pinned = pinned;
    }

    public Integer getAddressId() {
        return addressId;
    }

    public void setAddressId(Integer addressId) {
        this.addressId = addressId;
    }

    public String getCertificatePicture() {
        return certificatePicture;
    }

    public void setCertificatePicture(String certificatePicture) {
        this.certificatePicture = certificatePicture;
    }

    public String getReleaseDate() {
        return releaseDate;
    }

    public void setReleaseDate(String releaseDate) {
        this.releaseDate = releaseDate;
    }

    public Integer getApprovalStatus() {
        return approvalStatus;
    }

    public void setApprovalStatus(Integer approvalStatus) {
        this.approvalStatus = approvalStatus;
    }

    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    public String getPictures() {
        return pictures;
    }

    public void setPictures(String pictures) {
        this.pictures = pictures;
    }

    public String getPeripheralHotShop() {
        return peripheralHotShop;
    }

    public void setPeripheralHotShop(String peripheralHotShop) {
        this.peripheralHotShop = peripheralHotShop;
    }

    public String getOwnerReadme() {
        return ownerReadme;
    }

    public void setOwnerReadme(String ownerReadme) {
        this.ownerReadme = ownerReadme;
    }

    public List<HousingLabelBean> getHousingLabelList() {
        return housingLabelList;
    }

    public void setHousingLabelList(List<HousingLabelBean> housingLabelList) {
        this.housingLabelList = housingLabelList;
    }

    public List<String> getPicturesList() {
        return picturesList;
    }

    public void setPicturesList(List<String> picturesList) {
        this.picturesList = picturesList;
    }

    public List<HousingSupportingFacilitiesBean> getHousingSupportingFacilitiesList() {
        return housingSupportingFacilitiesList;
    }

    public void setHousingSupportingFacilitiesList(List<HousingSupportingFacilitiesBean> housingSupportingFacilitiesList) {
        this.housingSupportingFacilitiesList = housingSupportingFacilitiesList;
    }

    public AddressBean getAddress() {
        return address;
    }

    public void setAddress(AddressBean address) {
        this.address = address;
    }

    public DictBean getBusinessStatusDict() {
        if (businessStatusDict == null) return new DictBean();
        return businessStatusDict;
    }

    public void setBusinessStatusDict(DictBean businessStatusDict) {
        this.businessStatusDict = businessStatusDict;
    }

    public DictBean getPaymentMethodDict() {
        if (paymentMethodDict == null) return new DictBean();
        return paymentMethodDict;
    }

    public void setPaymentMethodDict(DictBean paymentMethodDict) {
        this.paymentMethodDict = paymentMethodDict;
    }

    public DictBean getTransferDict() {
        if (transferDict == null) return new DictBean();
        return transferDict;
    }

    public void setTransferDict(DictBean transferDict) {
        this.transferDict = transferDict;
    }

    public DictBean getPropertyTypeDict() {
        if (propertyTypeDict == null) return new DictBean();
        return propertyTypeDict;
    }

    public void setPropertyTypeDict(DictBean propertyTypeDict) {
        this.propertyTypeDict = propertyTypeDict;
    }

    public DictBean getFloorDict() {
        if (floorDict == null) return new DictBean();
        return floorDict;
    }

    public void setFloorDict(DictBean floorDict) {
        this.floorDict = floorDict;
    }

    public List<HousingOperatingIndustryBean> getIndustryList() {
        return industryList;
    }

    public void setIndustryList(List<HousingOperatingIndustryBean> industryList) {
        this.industryList = industryList;
    }

    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }

    public CommunityInformation getCommunityInformation() {
        return communityInformation;
    }

    public void setCommunityInformation(CommunityInformation communityInformation) {
        this.communityInformation = communityInformation;
    }

    public Integer getCommunityInformationId() {
        return communityInformationId;
    }

    public void setCommunityInformationId(Integer communityInformationId) {
        this.communityInformationId = communityInformationId;
    }

    @Override
    public int getItemType() {
        return item;
    }


    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        HousingInfoBean that = (HousingInfoBean) o;
        return Objects.equals(housingId, that.housingId);
    }

    @Override
    public int hashCode() {
        return Objects.hash(housingId);
    }
}
